import java.util.Scanner;

public class Main1622 {
    public static void main(String[] args) {
        Scanner sc=new Scanner(System.in);
        int n =sc.nextInt();
        int a,b;
        a=n/10;
        b=n%10;
        if(a>b){
            System.out.println(a);
        }else {
            System.out.println(b);
        }
    }
}
